<script setup lang="ts">
const test = () => {
  console.log('按钮点击....')
}
const beforeFun = () => {
  console.log('整个区域的按钮是1s防抖的')

}
</script>
<template>
  <button @click="test">按钮1</button>

  <h1>整个区域的按钮是1s防抖的</h1>
  
  <Debounce time="1000" :before="beforeFun">
    <button @click="test">按钮1</button>
    <button @click="test">按钮2</button>
  </Debounce>
</template>